﻿using System;
using System.Collections.Generic;
using System.Text;
using YouHP.Model.Group;
using YouHP.BLL;
using YouHP.Utility;
using System.Web;
using YouHP.Model;

namespace YouHP.Pages.Group
{
    public class CommentGroups: BasePage
    {

        protected List<GroupInfo> groupListLatest;
        protected List<GroupInfo> groupListHotest;
        protected List<GroupInfo> GroupListCommend;

        protected List<DiseaseInfo> DiseaseLst;
        protected List<TreatmentInfo> TreatmentLst;
        protected List<DistrictInfo> ProvinceList;
        protected PatientRecordInfo PrData;
        protected GroupSearchCondition cond =new GroupSearchCondition();
        protected int pageSize=21;
        protected int pageIndex=1;
        protected int groupCount=0;
        protected int n = 4;

        protected override void ShowPage()
        {
            base.ShowPage();
            this.AddLocation("推荐圈子", "/Group/CommentGroups.aspx");
            this.SetTitle("病友个人圈");

            groupListLatest = GroupBLL.Instance.GetGroupListLatest(n);
            groupListHotest = GroupBLL.Instance.GetGroupListHotest(n);

            PrData = PatientBLL.Instance.GetPatientRecordInfo(UserData.Id);
            cond.DiseaseId = PrData.DiseaseId;
            GroupListCommend = GroupBLL.Instance.GetGroupListCommend(pageSize,pageIndex,cond,out groupCount);

            DiseaseLst = DiseaseBLL.Instance.GetAllDiseaseByName("");
            TreatmentLst = TreatmentBLL.Instance.GetAllTreatmentByName("");
            ProvinceList = DistrictBLL.Instance.GetDistrictListByParent(0);

         
        }


    }
}
